package com.zygh.lz.service.impl;

import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.zygh.lz.dao.IllegalMapper;
import com.zygh.lz.entity.Illegal;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class IllegalService extends ServiceImpl<IllegalMapper, Illegal> {

    @Resource
    private IllegalMapper illegalMapper;

    public List<Illegal> illegalCode() {
        return illegalMapper.selectList(Wrappers.<Illegal>lambdaQuery().groupBy(Illegal::getType));

    }
}
